package de.koller.caldera.render.textures.surfaces;

import de.koller.aframe.gl.ATexture;
import de.koller.oceanFramework.gl.util.ParticleTexture;
import de.koller.oceanFramework.util.ColorIntUtil;
import org.lwjgl.opengl.GL11;

public class PlainBump extends ATexture implements ATexture.ITextureBuilder {

	@Override
	protected void setUp( TextureParameters tparam ) {
		tparam.builder = this;
		tparam.magFilter = GL11.GL_LINEAR;
		tparam.size = 512;
	}

	@Override
	public void build( final ParticleTexture texture ) {
		texture.clear( 0xff00ff00 );
		
		for( int x = 0; x < texture.getWidth(); x++ )
			for( int y = 0; y < texture.getHeight(); y++ ) {
				texture.setPixel( ColorIntUtil.getIntColor( 0xff, x, 128, 128 ), x, y );
			}
		
	}
	
}
